<template>
	<view>
		<YcolorBlock :list='myList' @change='clickItem'></YcolorBlock>
	</view>
</template>

<script>
	export default {
		data() {
			return {
				
				myList:[
					{
						color:'#ff3333',
						name:'C/C++攻城狮',
						data:'12'
					},
					{
						color:'#ffff33',
						name:'Java攻城狮',
						data:'322'
					},
					{
						color:'#ff33ff',
						name:'Python攻城狮',
						data:'323'
					},
					{
						color:'#0033ff',
						name:'PHP攻城狮',
						data:'323'
					},
					{
						color:'#003300',
						name:'.NET攻城狮',
						data:'323'
					}
				]
			}
		},
		methods: {
			clickItem(item){
				// 点击了
				console.log('item',item)
			},
		}
	}
</script>
<style lang="scss" scoped>
	
</style>
